package edu.cqbvc.dao;

import java.util.Objects;

public class BookInfo {
	private Integer bookId;
	private String bookName;
	private String bookAuthor;
	private Integer bookNumber;
	private String bookType;
	private Integer bookPages;
	private Integer bookLooked;
	private float bookPrice;
	
	
	public BookInfo() {
		
	}

	
	
	public BookInfo(Integer bookId, String bookName, String bookAuthor, Integer bookNumber, String bookType,
			Integer bookPages, Integer bookLooked, float bookPrice) {
		super();
		this.bookId = bookId;
		this.bookName = bookName;
		this.bookAuthor = bookAuthor;
		this.bookNumber = bookNumber;
		this.bookType = bookType;
		this.bookPages = bookPages;
		this.bookLooked = bookLooked;
		this.bookPrice = bookPrice;
	}



	public Integer getBookId() {
		return bookId;
	}
	public void setBookId(Integer bookId) {
		this.bookId = bookId;
	}
	public String getBookName() {
		return bookName;
	}
	public void setBookName(String bookName) {
		this.bookName = bookName;
	}
	public String getBookAuthor() {
		return bookAuthor;
	}
	public void setBookAuthor(String bookAuthor) {
		this.bookAuthor = bookAuthor;
	}
	public Integer getBookNumber() {
		return bookNumber;
	}
	public void setBookNumber(Integer bookNumber) {
		this.bookNumber = bookNumber;
	}

	public String getBookType() {
		return bookType;
	}

	public void setBookType(String bookType) {
		this.bookType = bookType;
	}

	public Integer getBookPages() {
		return bookPages;
	}



	public void setBookPages(Integer bookPages) {
		this.bookPages = bookPages;
	}



	public Integer getBookLooked() {
		return bookLooked;
	}



	public void setBookLooked(Integer bookLooked) {
		this.bookLooked = bookLooked;
	}



	public float getBookPrice() {
		return bookPrice;
	}



	public void setBookPrice(float bookPrice) {
		this.bookPrice = bookPrice;
	}



	@Override
	public int hashCode() {
		return Objects.hash(bookAuthor, bookId, bookLooked, bookName, bookNumber, bookPrice, bookType, bookPages);
	}



	@Override
	public boolean equals(Object obj) {
		if (this == obj) {
			return true;
		}
		if (!(obj instanceof BookInfo)) {
			return false;
		}
		BookInfo other = (BookInfo) obj;
		return Objects.equals(bookAuthor, other.bookAuthor) && Objects.equals(bookId, other.bookId)
				&& Objects.equals(bookLooked, other.bookLooked) && Objects.equals(bookName, other.bookName)
				&& Objects.equals(bookNumber, other.bookNumber)
				&& Float.floatToIntBits(bookPrice) == Float.floatToIntBits(other.bookPrice)
				&& Objects.equals(bookType, other.bookType) && Objects.equals(bookPages, other.bookPages);
	}



	@Override
	public String toString() {
		return getBookName();
	}
	
	
	
}  
